package org.rowan.infovis.soccer;

import com.sun.opengl.util.GLUT;
import com.sun.opengl.util.j2d.TextRenderer;
import java.awt.Color;
import java.awt.Font;
import javax.media.opengl.GL;
import javax.media.opengl.GLAutoDrawable;

public class Title {

    private float HEIGHT = 347f;
    private float WIDTH = 115f;
    private float PAD = 3f;

    private float LINK_WIDTH = 110f;
    private float LINK_HEIGHT = 40f;

    private float CSV_X = 440;
    private float CSV_Y = 300;

    private boolean onCSV = false;
    boolean csvSelected = false;

    private float PLAYER_X = 440;
    private float PLAYER_Y = 240;

    private boolean onPlayer = false;
    boolean playerSelected = false;

    private float FIELD_X = 440;
    private float FIELD_Y = 300;

    private boolean onField = false;
    boolean fieldSelected = false;

    private float startX = 0;
    private float startY = 0;

    private boolean csv = true;

    public void draw(GLAutoDrawable drawable, GL gl) {

        TextRenderer tr = new TextRenderer(new Font("SansSerif", Font.BOLD, 24));
        tr.beginRendering(drawable.getWidth(), drawable.getHeight());
        tr.setColor(Color.white);
        tr.draw("Soccer Visualization", 390, 450);
        tr.endRendering();

        TextRenderer names = new TextRenderer(new Font("SansSerif", Font.PLAIN, 18));
        names.beginRendering(drawable.getWidth(), drawable.getHeight());
        names.setColor(Color.white);
        names.draw("By: Edward Burns, Benjamin Hample", 360, 400);
        names.draw("Kevin McGarry, Robert Russell", 385, 370);
        names.endRendering();
    }

    private void drawBorder(GL gl) {
        gl.glPushMatrix();
        gl.glColor3f(1f, 1f, 1f);
        gl.glBegin(GL.GL_QUADS);
        gl.glVertex2f(0f, 0f);
        gl.glVertex2f(0f, HEIGHT);
        gl.glVertex2f(WIDTH, HEIGHT);
        gl.glVertex2f(WIDTH, 0f);
        gl.glEnd();
        gl.glPopMatrix();
    }
}



